<?php
/**
 * user: daishiqi
 * Date：2021/6/18
 * Time: 10:51 上午
 */

namespace App\Http\Services\Agreement;


use App\Http\Model\Agreement;

class AgreementService
{
    /**
     * @param $lastVersion
     * @param $userId
     * @return bool
     * @desc 获取用户是否需要同意协议
     */
    public function getIsNeedAgree($lastVersion, $userId)
    {
        return Agreement::getIsNeedAgree($lastVersion, $userId);

    }

    /**
     * @param $version
     * @param $userId
     * @return \Illuminate\Database\Eloquent\Builder|\Illuminate\Database\Eloquent\Model
     * @desc 用户同意协议额
     */
    public function userAgree($version, $userId)
    {
        return Agreement::userAgree($version, $userId);

    }


}